﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace EntityMode
{
    /// <summary>
    /// https://gitee.com/yuantianyou/pws.git
    /// </summary>
    public class Employee
    {
        /// <summary>
        /// 数据唯一标识符
        /// </summary>
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.None)]
        [Required]
        public Guid Id { get; set; }
        /// <summary>
        /// enum:
        /// 0：领导
        /// 1：党务人员
        /// 2：雇员
        /// </summary>
        [Required]
        public int Postion { get; set; }
        /// <summary>
        ///薪资 
        /// </summary>
        public float Salary { get; set; }
        /// <summary>
        /// 居住地址
        /// </summary>
       [StringLength(150)]
        [Required]
        public string? Address { get; set; }
        /// <summary>
        /// 性别
        /// </summary>
        [Required]
        public bool Gender { get; set; }
        /// <summary>
        /// 年龄
        /// </summary>
        [Required]
        public int Age { get; set; }
        /// <summary>
        /// 姓名
        /// </summary>
        [StringLength(50)]
        [Required]
        public string? Name { get; set; }
        /// <summary>
        ///出生日期 
        /// </summary>
        public DateTime BirthDate { get; set; }
        /// <summary>
        /// 血型
        /// </summary>
        [Required]
        public string? Bloodtype { get; set; }
        /// <summary>
        /// 是否婚配
        /// </summary>
        [Required]
        public int Marry { get; set; }
        /// <summary>
        /// 参加工作日期
        /// </summary>
        [Required]
        public DateTime WorkingDate { get; set; }
        /// <summary>
        /// 注册时间
        /// </summar
        [Required]
        public DateTime AddTime { get; set; }
    }
}
